<?php
class Foto extends CFormModel
{
	public $inscripcion_foto;
	
	public function rules() {
		return array(
			array('inscripcion_foto', 'file', 'types'=>'jpg','maxSize'=>1024 * 1024 * 1, 'tooLarge'=>'The file was larger than 1MB. Please upload a smaller file.',),	
		);
	}
	
	public function getForm()
	{
		
	return new CForm(array(
		
			'title'=>'Registro de Imagenes',
			'showErrorSummary'=>true,
			'elements'=>array(
		
				'<div class="span-9">',
				'inscripcion_foto'=>array(									
					'type'=>'file',
					'label'=>'TOMAR FOTO',
				),
				'</div>',				
				
			),
			'buttons'=>array(
				'previous'=>array(
					'type'=>'submit',
					'label'=>'Previous'
				),
				'submit'=>array(
					'type'=>'submit',
					'label'=>'Next'
				),
				'save_draft'=>array(
					'type'=>'submit',
					'label'=>'Save'
				)
			)
		), $this);
	}
}

?>